<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
	<th:block th:include="include :: header('获取合同信息列表服务')" />
</head>
<body class="gray-bg">
	<div class="container-div">
		<div class="row">
			<div class="col-sm-12 search-collapse">
				<form id="dept-form">
					<div class="select-list">
						<ul>
							<li>
								合同名称：<input type="text" name="contract_name"/>
							</li>
							<li>
								合同编号：<input type="text" name="contract_code"/>
							</li>
							<li>
								<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
										class="fa fa-search"></i>&nbsp;搜索</a>
								<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
										class="fa fa-refresh"></i>&nbsp;重置</a>
							</li>
						</ul>
					</div>
				</form>
			</div>

			<div class="col-sm-12 select-table table-striped">
				<table id="bootstrap-table"></table>
			</div>
	    </div>
	</div>
	<th:block th:include="include :: footer" />
	<script th:inline="javascript">
		$(function() {
		    var options = {
				url: ctx + "contract/get_contract_list",
				modalName: "获取合同信息列表服务",
				striped: false, //是否显示行间隔色
				pageNumber: 1, //初始化加载第一页
				pagination: true,//是否分页
				// sidePagination : 'server',//server:服务器端分页|client：前端分页
				pageSize: 10,//单页记录数
				pageList: [5, 10, 20, 30, 50],//可选择单页记录数
				showRefresh: false,//刷新按钮
				columns: [{
					field: 'selectItem',
					radio: true
				},
					{
						field: 'contractId',
						title: '合同ID',
						align: "left"
					},
					{
						field: 'contractName',
						title: '合同名称',
						align: "left"
					},
					{
						field: 'contractCode',
						title: '合同编号',
						align: "left"
					},
					{
						field: 'supplyDuration',
						title: '供应期限',
						align: "left"
					}]
			};
			$.table.init(options);
		});
	</script>
</body>
</html>